home *** CD-ROM | disk | FTP | other *** search
- #ifndef _ERRNO_H
- #define _ERRNO_H
-
- #ifndef _COMPILER_H
- #include <compiler.h>
- #endif
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- #define ENOERR 0 /* no error */
- #define E_OK ENOERR /* " " */
- #define EERROR 1 /* generic error */
-
- #define EDRNRDY 2 /* drive not ready */
- #define EDRVNR EDRNRDY /* " " " */
- #define EUKCMD 3 /* unknown command */
- #define EUNCMD EUKCMD /* " " */
- #define ECRC 4 /* crc error */
- #define E_CRC ECRC /* " " */
- #define EBADREQ 5 /* bad request */
- #define EBADRQ EBADREQ /* " " */
- #define ESEEK 6 /* seek error */
- #define E_SEEK ESEEK /* " " */
- #define EUKMEDIA 7 /* unknown media */
- #define EMEDIA EUKMEDIA /* " " */
- #define ESECTOR 8 /* sector not found */
- #define ESECNF ESECTOR /* " " " */
- #define EPAPER 9 /* no paper */
- #define EWRITE 10 /* write fault */
- #define EWRITEF EWRITE /* " " */
- #define EREAD 11 /* read fault */
- #define EREADF EREAD /* " " */
- #define EGENERIC 12 /* general mishap */
- #define EROFS 13 /* write protect */
- #define ECHMEDIA 14 /* media change */
- #define E_CHNG ECHMEDIA /* " " */
-
- #define EUKDEV 15 /* unknown device */
- #define EUNDEV EUKDEV /* " " */
- #define ENODEV EUKDEV /* " " */
- #define EBADSEC 16 /* bad sectors */
- #define EBADSF EBADSEC /* " " */
- #define EIDISK 17 /* insert disk */
- #define EOTHER EIDISK /* " " */
- /* (gap) */
- #define EINVAL 32 /* invalid function number */
- #define ENOENT 33 /* file not found */
- #define ESRCH ENOENT /* pid not found */
- #define EPATH 34 /* path not found */
- #define EMFILE 35 /* no more handles */
- #define EACCESS 36 /* access denied */
- #define EACCES 36 /* access denied */
- #define EPERM EACCESS /* " " */
- #define EBADF 37 /* invalid handle */
- #define ENOMEM 39 /* insufficient memory */
- #define EFAULT 40 /* invalid memory block address */
- #define ENXIO 46 /* invalid drive spec */
- #define EXDEV 48 /* cross device rename */
- #define ENMFILES 49 /* no more files (fsnext) */
- #define ENMFIL 49 /* no more files (from fsnext) */
-
- #define EBADARG 64 /* range error/context unknown */
- #define EINTERNAL 65 /* internal error */
- #define EINTRN EINTERNAL /* " " */
- #define ENOEXEC 66 /* invalid program load format */
- #define EPLFMT ENOEXEC /* " " " " */
- #define ESBLOCK 67 /* set block failed/growth restraints*/
- #define EGSBF ESBLOCK /* or memory block growth failure */
- /* (gap) */
- # define EMLINK 80 /* too many symbolic links */
- # define EEXIST 85 /* file exists, try again later */
- # define ENAMETOOLONG 86 /* name too long */
- # define ENOTTY 87
- # define ERANGE 88
- # define EDOM 89
-
- #define EINTR 128 /* this *should* be fake */
-
- extern int errno;
- extern int sys_nerr;
- extern char * sys_errlist[];
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif /* _ERRNO_H */
-